home *** CD-ROM | disk | FTP | other *** search
/ Reverse Code Engineering RCE CD +sandman 2000 / ReverseCodeEngineeringRceCdsandman2000.iso / RCE / Library / +ORC / Orc pac 9C / HOWTO93.TXT < prev    next >
Text File  |  2000-05-25  |  50KB  |  1,060 lines

  1.                      HOW TO CRACK, by +ORC, A TUTORIAL
  2.  
  3. ---------------------------------------------------------------------------
  4.  
  5.                 Lesson 9 (3): How to crack Windows, Hands on
  6.             Nagscreens galore (B): The 'Dead listing' approach
  7.  
  8. ---------------------------------------------------------------------------
  9.  
  10.                         [HEXWORKSHOP][PaintShopPro]
  11.  
  12.                    --------------------------------------
  13.  
  14.  
  15.   (Hic sunt tabulae: Best viewed with good old Courier 10)
  16.  
  17.      In this lesson I'll teach you another cracking technique
  18. known as "dead listing" approach, in opposition to the "live"
  19. cracking (through Softice/Winice) that we have used (and we'll
  20. use) most of the time.
  21.      Since this approach requires a good Hexeditor and a good
  22. disassembler (and a good Wordprocessor), it suits us well to
  23. begin the 'hands on'  part cracking what we need: a good
  24. Hexeditor.
  25.      I'll crack here the nagscreens out of Hexworkshop, Version
  26. 2.10 (32 bit version). A good and relatively quick (for Windoze's
  27. standards) application by Breakpoint software. Many among you
  28. will already have this hexeditor inside their Software
  29. collection, if not find it on the Web through an Archie search
  30. and download it through ftpmail... searching through the archies
  31. will give you something like this:
  32.  
  33. Host ftp.loria.fr    (152.81.10.10)
  34. Last updated 11:25 23 Oct 1996
  35. Location: /pub1/pc/win95/programr
  36. FILE -r--r--r-- 707906 bytes  02:00 13 Aug 1995 hworks32.zip
  37.  
  38. The exact NAME of this hexediting program is HWORKS32.EXE, it is
  39. 524288 bytes LONG, and its DATED 2 February 1996. This program
  40. has many little nag annoyances:
  41. -    shows a nagscreen reminding you how many days you have used
  42. the program;
  43. -    keeps a nag_string "unregistered version" on the main screen
  44. of the program;
  45. -    has, inside help, a "registration serial number form"...
  46. this is the number you could get registering... and should digit
  47. inside the HELP/ABOUT HEX WORKSHOP window form.
  48.  
  49.      Elsewhere in this tutorial we have already learned how to
  50. defeat this type of protection: through Winice breakpoints.
  51. Basically we would type a fake registration number (say
  52. '121212121212') and then look for the occurrences of our string
  53. in memory, and then search and investigate the manipulations
  54. undertaken by the protection scheme. In this way we would finally
  55. be able to crack the nagscreen procedure.
  56.      Fine, fine... this would indeed work, but I want to teach
  57. you through this lesson ANOTHER, completely different approach
  58. to cracking, which is and will be especially useful for
  59. 'nagscreen' and 'time-limit' cracking... i.e. the "dead listing"
  60. approach. This approach is a much more "relaxed" sort of crack,
  61. which  will work flawlessly most of the time.
  62.      This approach is particularly easy with Windows programs,
  63. since -as I have already told you a hundred times- the modularity
  64. of this overbloated atrocity makes it particularly easy for us
  65. little crackers to track back the -mostly primitive- protection
  66. methods utilized by the commercial programmers.
  67.      I remember older times, when programming was still an art
  68. for intelligent (not mercantile) beings, cracking the old (and
  69. sometime beautifully crafted) Z-80, CP/M and DOS programs. In
  70. those time 'a byte was a byte'! And good programmers found funny
  71. tricks in order to write 'tight' code. We old crackers used the
  72. 'dead listing' approach sitting (or snoozing) in pleasant (albeit
  73. a little battered) armchairs, inside a huge university library,
  74. drinking very good Martini Wodka (you would be well advised to
  75. use only Moskowskaja, coz non Russian Wodkas are repugnant). Four
  76. of us at a time, each one just looking at his paper listings. You
  77. cannot imagine how many little (unrelated) tricks we found inside
  78. the code cracking in that way! A hacker, a cracker (me), a 'real'
  79. programmer and an encryption specialist, all four sitting in the
  80. same room, exchanging pretty clever findings and sipping (much
  81. too many) good cocktails... it's long ago, those times (and
  82. societies) are gone for ever! Microsoft's abomination has
  83. unfortunately created this overbloated world of huge 'programs'
  84. which perform more slowly (and much more awkwardly) what the old
  85. programs did quickly and flawlessly.
  86.      You don't believe me? Why don't you just install Linux on
  87. your harddisk and see for yourself the difference between a good
  88. OS and Windoze? Just try it... you'll be amazed and you'll never
  89. go back... well, you'll actually do... only in order to crack the
  90. hell out of Windows: We'll never damage enough Microsoft's
  91. interests to compensate for this moronic situation: millions of
  92. stupid users have to wait hours (and this with microprocessors
  93. that are 1000 times quicker than the old 8086) to perform with
  94. MS_Word -slowly- what they could have done immediately with an
  95. old copy of Wordperfect for Dos.
  96.      Anyway, the huge dimension of all Windows' programs forces
  97. us to abandon the printed "dead listing" approach... printing in
  98. extenso the listing of a Windows program would consume a couple
  99. of ink cartridges and could easily take ages... therefore we can
  100. indeed still crack with the "dead listing" method, and we can
  101. indeed still drink our Martinis (and we do, Oh Yessir), but we
  102. must keep the overbloated listings off page, on our PC, printing
  103. only the small part of them that are relevant to our crack.
  104.  
  105.      As I said at the beginning, for this art of cracking you'll
  106. need basically only two programs (and you will NOT need
  107. Softice/Winice).
  108.  
  109. 1)        A disassembler like W32DASM (or another good one) in
  110. order to find the protection scheme.
  111. You will probably already possess it (else how did you crack
  112. until now?)... if not find the last version on the Web -through
  113. an Archie search- and download it -through ftpmail-, Searching
  114. the archies will give you something like this:
  115.  
  116. Host ftp.funet.fi    (128.214.248.6)
  117. Last updated 07:57  1 Jan 1997
  118. Location: /pub/mirrors/ftp.cdrom.com/pub/simtelnet/win3/prog
  119. FILE    -rwxrwxr-x  650327 bytes  23:25 28 Oct 1996  w32dasm6.zip
  120.  
  121. 2)        An hexeditor (Use Hexworkshop version 2.10 itself,
  122. since we are already cracking it :=) in order to defeat the
  123. protection scheme as soon as you have found it. OK, enough, let's
  124. crack.
  125.  
  126. Here is how the "dead listing" approach works:
  127. 1)   Run the program you want to crack, in this case Hexworkshop,
  128. look at all the nag_strings and write them down (I mean snap them
  129. down -automatically- from screen... see elsewhere in my tutorial
  130. how to get and crack snap32);
  131. 2)   Wdasm the file (that means: 'open' it inside the
  132. disassembler in order to get the listing).
  133. 3)   Transfer the listing to your favorite wordprocessor (we will
  134. not need Wdasm any more, bye)
  135. 4)   Search (Find) inside your wordprocessor the nag_references,
  136. say, in our case, the string "unregistered version"
  137.  
  138. You'll immediately land inside following piece of code:
  139. :MAIN_NAG_ROUTINE
  140. :00415732 CC              int 03
  141. :00415733 CC              int 03
  142. :00415734 CC              int 03
  143. :00415735 CC              int 03
  144. :00415736 CC              int 03
  145. :00415737 CC              int 03
  146. :00415738 CC              int 03
  147. :00415739 CC              int 03
  148. :0041573A CC              int 03
  149. :0041573B CC              int 03
  150. :0041573C CC              int 03
  151. :0041573D CC              int 03
  152. :0041573E CC              int 03
  153. :0041573F CC              int 03
  154. :00415740 55              push ebp
  155. :00415741 8BEC            mov ebp, esp
  156. :00415743 6AFF            push FFFFFFFF
  157. :00415745 6873584100      push 00415873
  158. :0041574A 64A100000000    mov eax, fs:[00000000]
  159. :00415750 50              push eax
  160. :00415751 64892500000000  mov fs:[00000000], esp
  161. :00415758 81EC0C020000    sub esp, 0000020C
  162. :0041575E 53              push ebx
  163. :0041575F 56              push esi
  164. :00415760 57              push edi
  165. :00415761 898DE8FDFFFF    mov [ebp-00000218], ecx
  166. :00415767 8B450C          mov eax, [ebp+0C]
  167. :0041576A 50              push eax
  168. :0041576B 6A73            push 00000073
  169. :0041576D 8B8DE8FDFFFF    mov ecx, [ebp-00000218]
  170. :00415773 E87EFC0100      call 004353F6
  171. :00415778 C745FC00000000  mov [ebp-04], 00000000
  172. :0041577F 8B8DE8FDFFFF    mov ecx, [ebp-00000218]
  173. :00415785 83C144          add ecx, 00000044
  174. :00415788 E84EF40100      call 00434BDB
  175. :0041578D C645FC01        mov [ebp-04], 01
  176. :00415791 8B85E8FDFFFF    mov eax, [ebp-00000218]
  177. :00415797 C70028AE4500    mov dword ptr [eax], 0045AE28
  178.  
  179. *StringData Ref from Data Obj->"An unregistered version of Hex"
  180.                              ->"Workshop has been on"
  181.                             |
  182. :0041579D 68085B4600      push 00465B08
  183. :004157A2 8D85F4FDFFFF    lea eax, [ebp-0000020C]
  184.  
  185. Good, we immediately see that the above routine starts at
  186. instruction
  187. :00415740 55              push ebp
  188. Therefore now we'll search our listing for following string:
  189. call 00415740                 (that is: who calls here?).
  190. The reason we must search for the caller is very simple: there
  191. is no conditional jump inside the piece of code above... and
  192. therefore it'll very unlikely hide a protection and/or a check
  193. time or nag routine. If we do perform our search for the caller
  194. we'll immediately land inside following routine:
  195.  
  196. : CALL_NAG_ROUTINE
  197. :00415DAC 55              push ebp          ;pusha lotta values
  198. :00415DAD 8BEC            mov ebp, esp
  199. :00415DAF 6AFF            push FFFFFFFF
  200. :00415DB1 68045E4100      push 00415E04
  201. :00415DB6 64A100000000    mov eax, fs:[00000000]
  202. :00415DBC 50              push eax
  203. :00415DBD 64892500000000  mov fs:[00000000], esp
  204. :00415DC4 83EC54          sub esp, 00000054
  205. :00415DC7 53              push ebx
  206. :00415DC8 56              push esi
  207. :00415DC9 57              push edi
  208. :00415DCA 894DA0          mov [ebp-60], ecx
  209. :00415DCD 6A00            push 00000000
  210. :00415DCF 8B4508          mov eax, [ebp+08]
  211. :00415DD2 50              push eax
  212. :00415DD3 8D4DA4          lea ecx, [ebp-5C]  ;for the call
  213. :00415DD6 E865F9FFFF      call 00415740    ;*** HERE !!! ***
  214. :00415DDB C745FC00000000  mov [ebp-04], 00000000
  215. :00415DE2 8D4DA4          lea ecx, [ebp-5C]
  216. :00415DE5 E804F70100      call 004354EE
  217. :00415DEA C745FCFFFFFFFF  mov [ebp-04], FFFFFFFF
  218. :00415DF1 E805000000      call 00415DFB
  219. :00415DF6 E913000000      jmp 00415E0E
  220. :00415DFB 8D4DA4          lea ecx, [ebp-5C]
  221. :00415DFE E8FD000000      call 00415F00
  222. :00415E03 C3              ret
  223.  
  224. Good, OK. Now -once more- who calls this function? As -here too-
  225. we don't have any conditional jumps, we are compelled to look
  226. further inside the green branches of our code_tree.
  227. Let's go on: searching for
  228. call 00415DAC       (the beginning of the above function)
  229. we will land inside following code:
  230.  
  231. :WILL     _I_CALL_THE_CALL_NAG_ROUTINE_?
  232. :0040254C 6808414500      push 00454108
  233. :00402551 8D8568FEFFFF    lea eax, [ebp-198]
  234. :00402557 50              push eax
  235. :00402558 E893460200      call 00426BF0
  236. :0040255D 83C408          add esp, 8
  237. :00402560 0FBF0508414500  movsx word ptr eax, [00454108]
  238. :00402567 85C0            test eax, eax
  239. :00402569 0F8586000000    jne 004025F5  ;jump 1 over CALL_NAG
  240. :0040256F 8B8D40FEFFFF    mov ecx, [ebp-1C0]
  241. :00402575 E8D3350100      call 00415B4D
  242. :0040257A 85C0            test eax, eax
  243. :0040257C 0F841B000000    je 0040259D
  244. :00402582 8B8D40FEFFFF    mov ecx, [ebp-1C0]
  245. :00402588 E866360100      call 00415BF3
  246. :0040258D 8B8D40FEFFFF    mov ecx, [ebp-1C0]
  247. :00402593 E8DF360100      call 00415C77
  248. :00402598 E953000000      jmp 004025F0  ;jump 2 over CALL_NAG
  249. :0040259D 8B8D40FEFFFF    mov ecx, [ebp-1C0]
  250. :004025A3 E83D370100      call 00415CE5 ;(month year routine)
  251. :004025A8 898570FFFFFF    mov [ebp-90], eax
  252. :004025AE 83BD70FFFFFF00  cmp dword ptr [ebp-90], 0
  253. :004025B5 0F8417000000    je 004025D2    ;jump 3 over CALL_NAG
  254. :004025BB 8B8570FFFFFF    mov eax, [ebp-90]
  255. :004025C1 50              push eax
  256. :004025C2 8B8D40FEFFFF    mov ecx, [ebp-1C0]
  257. :004025C8 E8DF370100      call 00415DAC ;HERE! CALL_NAG! *
  258. :004025CD E91E000000      jmp 004025F0
  259. :004025D2 8D8D7CFFFFFF    lea ecx, [ebp-84];jump 3 lands here
  260. :004025D8 E88C420200      call 00426869
  261. :004025DD 85C0            test eax, eax
  262. :004025DF 0F840B000000    je 004025F0
  263. :004025E5 8D8D7CFFFFFF    lea ecx, [ebp-84]
  264. :004025EB E8FE2E0300      call 004354EE
  265. :004025F0 E91E000000      jmp 00402613     ;jump 2 lands here
  266. :004025F5 8D8D7CFFFFFF    lea ecx, [ebp-84];jump 1 lands here
  267. :004025FB E869420200      call 00426869
  268.  
  269. Now have a good look at the code above: As you can see there are
  270. only three possible jumps which will NOT call the CALL_NAG
  271. routine. The one at
  272. :00402598 E953000000          jmp 004025F0 (Jump 2)
  273. is not conditional, and therefore very rarely used for nagscreens
  274. protections. Besides, it links to another unconditional jump and
  275. it's most probably a "Quick_out" way... let's eliminate it, at
  276. least for now.
  277. We remain with only two jumps over the NAG_SCREEN call routine:
  278. 00402569 0F8586000000         jne 004025F5 (jump 1)
  279. and
  280. 004025B5 0F8417000000         je 004025D2      (jump 3)
  281.  
  282.      You may investigate both of them, but, hey, you could
  283. eliminate one more jump, again, just using a little Zen code
  284. feeling): see how the jump condition for jump_3 is a base pointer
  285. value [ebp-90], while the one for jump_1 is a memory fixed
  286. location [00454108]... this sort of condition is usually a green
  287. light, for compiler reasons I'll not delve inside here. Therefore
  288. let's have a closer look at it and let's forget jump 3, at least
  289. for now.
  290.  
  291. :JUMP_1_UNDER_THE_LUPE
  292. :0040254C 6808414500      push 00454108 ;values for
  293. :00402551 8D8568FEFFFF    lea eax, [ebp-198]
  294. :00402557 50              push eax      ;the following
  295. :00402558 E893460200      call 00426BF0 ;call
  296. :0040255D 83C408          add esp, 8 ;modify stack
  297. :00402560 0FBF0508414500  movsx word ptr eax, [00454108] ;HERE
  298. :00402567 85C0            test eax, eax ;conditional test
  299. :00402569 0F8586000000    jne 004025F5  ;jump over CALL_NAG
  300.  
  301. What will then this mysterious [00454108] location be? Don't you
  302. feel it? It's the ACTIVATOR! The location with the flag, which
  303. sets the whole nag screen galore for Hexworkshop! Our cracking
  304. job is already finished!
  305.      We don't need anything more: we don't need any fiddling with
  306. breakpoints, nor to examine hundreds of irrelevant calls... with
  307. Windows this kind of "dead listing" cracks works so smooth I
  308. could shriek!
  309.      But, hey, OK, we will continue our snooping, for the sake
  310. of it and just in order to be completely sure... it's not
  311. necessary, but let's do it anyway... check a little more
  312. around... search, inside your huge listing, all the other
  313. occurrences of the same [00454108] location... you'll get no more
  314. than 5 hits. The most striking one from our cracking point of
  315. view being the following occurrence:
  316.  
  317. :00402770 898574FFFFFF   mov [ebp-8C], eax ;save old eax
  318. :00402776 0FBF0508414500 movsx word ptr eax, [00454108];FLAG*
  319. :0040277D 85C0           test eax, eax     ;flag is zero?
  320. :0040277F 0F8528000000   jne 004027AD    ;nope, so we won't
  321. :00402785 8B4DEC         mov ecx, [ebp-14]
  322. :00402788 E883280000     call 00405010   ;call this, nor
  323. :0040278D 898574FFFFFF   mov [ebp-8C], eax ;write
  324.  
  325. * Possible StringData Ref from Data Obj ->"Unregistered
  326. Version"
  327.                      |
  328. :00402793 6854494600    push 00464954   ;on the screen
  329. :00402798 685C800000    push 0000805C   ;& we'll jump over
  330. :0040279D 6800400000    push 00004000   ;these pushes
  331. :004027A2 8B8D74FFFFFF  mov ecx, [ebp-8C]
  332. :004027A8 E823280000    call 00404FD0   ;and this call
  333.  
  334. * Possible StringData Ref from Data Obj ->"ControlBars"
  335.                   |
  336. :004027AD 686C494600   push 0046496C     ;directly here
  337.  
  338. Well, yes, now it's more than enough, thanks... location
  339. [00454108] seems indeed to be the flag we are searching.
  340. Confirmed. Struck and sunk! Now let's quickly crack Hexworkshop:
  341.  
  342. *** CRACK FOR HEXWORKSHOP VERSION 2.10 by +ORC (January 1997) **
  343. Use hexworkshop itself (no more debug/symdeb, coz we are working
  344. with the overbloated Microsoft monstrosity) and search inside the
  345. code of the copy on your harddisk for the hex sequence:
  346.      08414500
  347. that's the code for our flag_location, duh?
  348.  
  349. ****(a short digression): BE CAREFUL SEARCHING FOR BYTES *****
  350. Be careful with instructions you try to search for. You should
  351. only search for instructions that don't change the bytes they
  352. assemble to, depending on their location in memory. For example,
  353. searching for the following instructions presents no problem:
  354. PUSH      DX
  355. POP       [DI+4]
  356. ADD       AX, 100
  357. but searching for the following instructions CAN cause
  358. unpredictable results:
  359. JE        123
  360. CALL      MYFUNC
  361. LOOP      100
  362. **** (end) ********************************* **** **** ****
  363.  
  364. Searching for the byte sequence 08 41 45 00 you will obviously
  365. find the several occurrences of it we have seen before... you
  366. have to modify only one location though, the one followed by the
  367. two bytes
  368. 0F85...  (jne after CALL_NAG)
  369. at the FIFTH (and sixth) position after the search string,
  370. because that's the location we are looking for.
  371. Once you found it, write over the byte
  372. 85
  373. the byte
  374. 84
  375. and now you'll have modified the jne in a (je after CALL_NAG).
  376.      We'll now jump if equal (as all men should be, by the
  377. way)... Look!... no more nagscreens to annoy our proven aesthetic
  378. perception, no more silly protections to blemish our suave future
  379. hexediting around :=)
  380. I almost forgot... that's obviously not enough... you must as
  381. well modify the location at :0040277F
  382.  
  383. :0040277F 0F8528000000   jne 004027AD   ;jump over 'unregistered'
  384. to
  385. :0040277F 0F8428000000   je 004027AD    ;jump equal!
  386.  
  387. in order to have a well cracked copy of our target.
  388.  
  389. [PSP 32]
  390. Can we apply this 'dead listing' approach to other programs? Can
  391. we use the same strategies for other protection schemes?
  392. Sure! Let's remain a little more inside the nagscreens
  393. protections.
  394.      A logical step, after the invention of the nagscreen itself,
  395. has been the "mingling" of the nagscreen calling routine. In this
  396. kind of protection the nagscreen routines are 'amalgamated' with
  397. other routines, which cannot be skipped as they are essential for
  398. the working of the program. The main disadvantage of this
  399. approach, for the mercantile protectionists, is that they have
  400. therefore to prepare TWO different versions of their programs:
  401. a 'nagscreened' one and a 'clean' one, since else we would
  402. immediately be able to transform the crippled program in a fully
  403. functional one using the same approach they would use to
  404. 'uncripple' it.
  405.      Such mingling is therefore only used by major programs which
  406. are well established on the market and can afford the 'doubled'
  407. approach. This is the case of the last versions of PaintShopPro
  408. (PSP).
  409.      Even in this case, though, we can crack nice enough, as I
  410. will now demonstrate you with PaintShopPro version 3.2 (a 32 bit
  411. program for Windows 95).
  412.      You will probably already possess it, if not find the last
  413. version on the Web -through an Archie search- and download it
  414. -through ftpmail-, Searching the archies will give you something
  415. like this:
  416.  
  417. Host ftp.mds.mdh.se    (130.238.252.239)
  418. Last updated 08:10  4 Dec 1996
  419. Location: /pub/windows/win95/graphic_utils/paintshop
  420. FILE  -rw-r--r--  311542 bytes  15:11 27 Jul 1996  psp32bit.zip
  421.  
  422.      We have seen in the preceding lesson (-> lesson 9.2) how to
  423. disrupt, through the usual Winice 'live' approach, the
  424. PaintShopPro nagscreens for Windows 3.1., cracking the older
  425. versions of this program. Instead we will now try our 'dead
  426. listing' approach for PSP 32 and PSP Version 4.1 (both 32 bit
  427. programs).
  428.      Let's fire PSP32 (I am using here the shareware version with
  429. a PSP.EXE of 1.042.944 bytes, dated 27 December 1995). Let's have
  430. a good look at the nagscreen (snapping it), OK, that's enough.
  431.      Now load the target inside Wdasm32 (I am using here version
  432. 5 of Wdasm, you'll find cracked versions of it everywhere on the
  433. Web).
  434.      As soon as you have the complete (huge) listing of PSP.EXE
  435. use the option "Save disassembly to text file"... you'll get a
  436. huge text file (with 12.590.025 bytes, gosh).
  437.      Load it inside a (good and quick, i.e. not Microsoft's)
  438. Wordprocessor and let's first of all have a look at the code
  439. preceding and following our nagscreen (at this point -if you are
  440. not completely imbecile- you should already have grasped the
  441. foundation techniques of my "dead listing" cracking approach).
  442.      You will see that in the code of PSP we have a lot of USER
  443. calls. Therefore we cannot use the same easy 'find the caller'
  444. approach used before (more about code mingling later).
  445.      Have a look at the following piece of code (the Stringdata
  446. for the Shareware notice has landed us there) there is a
  447. GetDlgItem(), which is User32.EB and a EnableWindow(), which is
  448. User32.AB.
  449.      GetDlgItem(), as you should know, returns the handle of the
  450. specified ID control (or zero if error). The ID number is the
  451. parameter passed, the returned value is the hdlg (handle of the
  452. dialog box of ID).
  453.  
  454. :0041DB69 891D38A04B00    mov [004BA038], ebx     ;ebx in here
  455. **
  456. :0041DB6F 6A6C             push 6C
  457. :0041DB71 881DF4134C00    mov [004C13F4], bl      ;bl in here **
  458. :0041DB77 56               push esi
  459.  
  460. * Reference To: GetDlgItem, Ord:00EBh in USER32.dll
  461.                                 |
  462. :0041DB78 FF154C5A4C00    call dword ptr [004C5A4C]   ;callnag-1
  463. :0041DB7E 50               push eax
  464.  
  465. * Reference To: EnableWindow, Ord:00ABh in USER32.dll ;callnag-2
  466.                                 |
  467. :0041DB7F FF15DC594C00    call dword ptr [004C59DC]
  468.  
  469. *StringData Ref from Data Obj->"Paint Shop Pro Shareware Notice"
  470.                            |
  471. :0041DB85 6820174C00      push 004C1720
  472. :0041DB8A 56              push esi
  473.  
  474. Now follow me closely:
  475. 1)   Since the following code pushes two locations (one with bx
  476. and the other with bl) just before calling the  GetDlgItem and
  477. EnableWindow routines for the "PaintShopPro Shareware Notice"
  478. Window...
  479. 2)   ...we just need to search these locations ELSEWHERE,
  480. "around" the above section of the code. Let's do it... Searching
  481. the STRING "[004BA038]" we'll fetch inside our wordprocessed
  482. listing two more occurrences: Let's look at the first one: this
  483. piece of code compares to 1 our location just after enabling a
  484. Window:
  485.  
  486. :REFERENCE_1_OF_OUR_[004BA038]
  487. * Reference To: EnableWindow, Ord:00ABh in USER32.dll
  488.                            |
  489. :0041DA41 FF15DC594C00   call dword ptr [004C59DC]
  490. :0041DA47 C605F4134C0002 mov byte ptr [004C13F4],2
  491. :0041DA4E 833D38A04B0001 cmp dword ptr [004BA038],1 ;HERE!! **
  492. :0041DA55 7510           jne 0041DA67 ;and the conditional jump!
  493. :0041DA57 6A00           push 00000000 ;If equal (Zero flag),
  494. :0041DA59 6A6C           push 0000006C ;push these parameters
  495. :0041DA5B 6811010000     push 00000111 ;for the PostMessage
  496. :0041DA60 56             push esi     ;function...
  497.  
  498. * Reference To: PostMessageA, Ord:01A3h in USER32.dll
  499.                           |
  500. :0041DA61 FF155C594C00   call dword ptr [004C595C] ;...call)
  501. :0041DA67 B801000000     mov eax, 1        ;our jump here: flag=1
  502. :0041DA6C E9EE030000     jmp 0041DE5F  ;end of code snippet, this
  503.  
  504. jumps to the "popping away" part of the code...
  505. :0041DE5F 5D                  pop ebp
  506. :0041DE60 5F                  pop edi
  507. :0041DE61 5E                  pop esi
  508. :0041DE62 5B                  pop ebx
  509. :0041DE63 81C434050000        add esp, 00000534
  510. :0041DE69 C21000              ret 0010
  511.  
  512.      AhHa! The value 111! (at :0041DA5B). You know what that
  513. means, don't you? For the newbyes among you that don't, learn it
  514. here (the others can skip):
  515. ************ THE 111 WM_COMMAND RELEVANCE, by +ORC ********
  516. The function PostMessage() has following structure:
  517. PostMessage(HWND hWnd, UINT uMsg, WPARAM wMsgParam1, LPARAM
  518. lMsgParam2)Where hWnd is the receiving Window, UINT is TRUE or
  519. FALSE WPARAM is a 16 bit value and LPARAM a 32 bit one!
  520. Windows' applications use PostMessage() to deliver WM_Message
  521. requests... and parameter 111 is WM_COMMAND!
  522. Write it on your cracking notes and underline it! 1 is IDOK, 2
  523. is IDCANCEL and 111 is WM_COMMAND.
  524.      WM_COMMAND is extremely important for understanding the
  525. behaviour of the application you want to crack, because the
  526. handler for WM_COMMAND is where that application deals with user
  527. commands, such as menu selctions, dialog push button clicks,
  528. etcetera. In other words all what makes the 'guts' of an
  529. application.
  530.      An application can tell wich command a user gives through
  531. the wParam parameter to the WM_COMMAND message.
  532.      These values are (almost) always part of the application's
  533. menu resources, and it is easy to get the menu ID values through
  534. any utility for resources dumping.
  535. ************ (end) **************
  536.      OK, so the above listed piece of code has a jump over the
  537. PostMessage routine which (probably) disables the nag screen (6C
  538. is the same ID, for both pieces of code we have seen)...let's try
  539. a "weak" crack on it:
  540.  
  541. ***** WEAK CRACK FOR PSP32, by +ORC, January 1997 ********
  542.  
  543. 1)   Use Hexworks32
  544. 2)   Load PSP.EXE
  545. 3)   Search for the bytes sequences of the instructions
  546. :0041DA4E 833D38A04B0001      cmp dword ptr [004BA038],1
  547. :0041DA55 7510                jne 0041DA67
  548. which are followed by the pushes:
  549. :0041DA57 6A00                push 00000000 ;zero
  550. :0041DA59 6A6C                push 0000006C ;ID
  551. :0041DA5B 6811010000          push 00000111 ;WM_COMMAND
  552.  
  553. And as a quick crack (but there are more elegant ways) we can
  554. 4) substitute the byte '75' at :0041DA55 with a 74, transforming
  555. the jne in a je, as usual, inverting the jumps. Jump if equal!
  556.  
  557. Since I have been (blandly) critized by fellow scholars for
  558. speaking all the time of more elegant ways and yet presenting
  559. only simple ways, here IS a more elegant crack for this code:
  560.  
  561. 4)   Substitute with a new ONE the first TWO instructions:
  562. :0041DA4E 66C70538A04B000100   mov word ptr [004BA038],1
  563. and leave all the rest unchanged:
  564. :0041DA57 6A00                push 00000000 ;zero
  565. :0041DA59 6A6C                push 0000006C ;ID
  566. :0041DA5B 6811010000          push 00000111 ;WM_COMMAND
  567. *****************************
  568. As you can see, we have just moved the flag '1' inside our
  569. location, instead of comparing and jumping away as in the
  570. original code and in the quickly cracked one. Estilo muchissimo
  571. elegante.
  572.  
  573. Since this lesson was thought as +HCU material, here is the
  574. result of the work on it made by (some of) my students:
  575.  
  576. JANUARY 1997: THIS PART OF LESSON 9.3 HAS BEEN MODIFIED (OR
  577. ADDED) BY THE +HCU STUDENTS OF UNIT 4
  578.  
  579. Let's finish our cracking of the nagscreens of the whole PaintShopPro family with version 4.1, which is the most recent we know of. I am using here PSP.EXE 1.151.488 bytes from 1 Sep 1996, fetch it through the archies. We will crack this shareware program BETTER than the registered version, since we will completely eliminate any nagscreen and we'll not ever have the welcome screen that REMAINS inside the registered version. We'll do this 'in a hurry', since it is not +ORC speaking, but some of h
  580. enough about the 'dead listing' method to be able to follow. No
  581. Winice in our hands, Ladies and Gentleman, We never used it on
  582. this program. (Well... we actually did, before reading 9.3, but
  583. it brought us nowhere, for this crack we (almost) DID NOT,
  584. following +his instructions)
  585. 1) Get the 'dead listing' of psp.exe (it's huge)
  586. 2) Load it inside a fast wordprocessor
  587. 3) Find the string 'Purchasing' at :00406710
  588. 4) short after 'Purchasing' the only location compared and loaded
  589. is location [004BC218]. Let's call it 'BINGO' and let's hope
  590. it'll work.
  591. 5) this location is handled inside a small part of the code
  592. :00406290 to :004067B5, this reduces the more than one million
  593. bytes to 1317 bytes we'll have to examine, not bad.
  594. 6) Let's print this nagging part of the code and let's feel it
  595. a little
  596. 7) Let's see the possible cracks we could think of (we repeat,
  597. here is not +ORC's but his students at work, we are not perfect).
  598. You'll see this piece of code
  599. :FIRST_ATTEMPT (NOT SO GOOD)
  600. :004065D0 50                  push eax
  601. :004065D1 64892500000000      mov fs:[00000000], esp
  602. :004065D8 81ECB4000000        sub esp, 000000B4
  603. :004065DE 833D18C24B0000      cmp dword ptr [004BC218], 0 ;Is
  604. BINGO zero?
  605. :004065E5 56                  push esi
  606. :004065E6 57                  push edi
  607. :004065E7 0F85A0010000        jne 0040678D ;not really
  608. this is 'pentium optimised' code, with a couple of pushes
  609. 'inside' the two logically consecutive instructions following the
  610. double 80586 fetching... on a 80486 you would have had:
  611. push esi; push edi; cmp dword ptr [004BC218], 0; jne 0040678D
  612. We may just try substituting a 0F84 at :004065E7 (that is a jump
  613. equal instead of the jne) and BOUM! We get an 'inamovible'
  614. nagscreen, No way to click it away, it covers the main program
  615. PaintShopPro for the eternity. This confirms that we are on the
  616. right track (it's a green light). Uncrack the code (or reload the
  617. original nagged program). Now look here:
  618. :SECOND_ATTEMPT (NOT SO GOOD)
  619. :00406495 E95AEA0900         jmp 004A4EF4
  620. :0040649A 33F6               xor esi, esi
  621. :0040649C C745FCFFFFFFFF     mov [ebp-04], FFFFFFFF
  622. :004064A3 893518C24B00       mov [004BC218], esi ;load esi in
  623. BINGO
  624. Since :00406495 jumps away, it would be interesting to know who
  625. the cuckoos lands at :0040649A. You'll quickly discover that
  626. there are two jumps in this area. One 'xores' the esi before
  627. loading it in our location, the other one does not:
  628. :0040641C 747C       je 0040649A        ;xores esi
  629. :0040646F EB2B       jmp 0040649C  ;does not xore esi
  630. So you may be tempted to try 'ça passe ou ça casse' following
  631. cracks:
  632. :0040641C 747E       je 0040649C  ;no xoring even if it should
  633. (THIS DOES NOT CHANGE ANYTHING)
  634. :0040646F EB19       jmp 0040649A ; xoring even if it should not
  635. (THIS CRASHES)
  636. Bad score: a frozen nagscreen, a nothing and a crash. Three to
  637. zero for our enemies. Let's look a little more around our 1317
  638. bytes listing.
  639.  
  640. Well, what else?
  641. The following code refers THREE TIMES to our location, that's a
  642. lot, let's hope it does not suck:
  643. :THREE_SISTER_BINGOS
  644. :00406547 33C0            xor eax, eax  ;xor
  645. :00406549 85C0            test eax, eax ;test ax
  646. :0040654B 7513            jne 00406560 ;don't move in cx
  647. :0040654D 8B0D18C24B00 1! mov ecx, [004BC218] ;move in cx
  648. :00406553 85C9            test ecx, ecx ;test cx
  649. :00406555 7418            je 0040656F  ;don't call Updatewin
  650. :00406557 6A01            push 1
  651. :00406559 8B01            mov eax, [ecx] ;move cx in ax
  652. :0040655B FF5004          call [eax+04]  ;and call here
  653. :0040655E EB0F            jmp 0040656F   ;don't call Updatewin
  654. :00406560 A118C24B00  2!  mov eax, [004BC218]  ;move in ax soon
  655. :00406565 8B4820          mov ecx, [eax+20]
  656. :00406568 51              push ecx
  657. :00406569 FF15C4014C00 call dword ptr [004C01C4] ;call
  658. Updatewindow
  659. :0040656F 6A00            push 0
  660. :00406571 A118C24B00  3!  mov eax, [004BC218]  ;move in ax later
  661.  
  662. Well, something fishy here, don't you feel it? Who comes in here?
  663. From where? Let's have a GOOD look at the 'preamble', i.e. the
  664. part of the code that 'switches' to our THREE_SISTER_BINGOS block
  665. above:
  666. :PREAMBLE_TO_THREE_SISTER_BINGOS
  667. :004064DD FF15BCF24B00    call dword ptr [004BF2BC] ;check this
  668. loc
  669. :004064E3 85C0            test eax, eax       ;test
  670. :004064E5 744E            je 00406535              ;zero, go 6535
  671. :004064E7 B896000000      mov eax, 96              ;load par 96
  672. :004064EC 3945E0          cmp [ebp-20], eax     ;compare this
  673. :004064EF 7C44            jl 00406535              ;lower, go
  674. 6535
  675. :004064F1 3945E4          cmp [ebp-1C], eax     ;compare that
  676. :004064F4 7C3F            jl 00406535             ;lower, go 6535
  677. :004064F6 8B4508          mov eax, [ebp+08]     ;load this
  678. :004064F9 85C0            test eax, eax         ;test it
  679. :004064FB 7504            jne 00406501          ;do not xor
  680. and...
  681. :004064FD 33C0            xor eax, eax          ;xor and
  682. :004064FF EB03            jmp 00406504          ;do not
  683. :00406501 8B4020          mov eax, [eax+20]     ;...load this
  684. :00406504 6A00            push 0                ;push
  685. :00406506 8B4DE0          mov ecx, [ebp-20]     ;load ecx
  686. :00406509 6A00            push 0                  ;push
  687.  
  688. Let's have a look at the 6535 routine of the switch PREAMBLE:
  689. :00406535 E836560100       call 0041BB70
  690. and
  691. :41BB70 A118C34B00         mov eax, [004BC318]
  692. :41BB75 85C0               test eax, eax
  693. :41BB77 7407               je 0041BB80
  694. :41BB79 50                 push eax
  695. :41BB7A FF1530F54B00       call dword ptr [004BF530] ;globalFree
  696. :41BB80 C70518C34B00       mov dword ptr [004BC318], 0
  697. :41BB8A C3                 ret
  698.  
  699. Well, let's try along, what happen if we substitute a ret at
  700. :00406535?
  701. :00406535 C390909090     ret and nops
  702. Nothing at all.
  703. And what if we substitute here
  704. :004064F6 8B4508                  mov eax, [ebp+08]
  705. :004064F9 85C0                    test eax, eax
  706. :004064FB 7504                    jne 00406501
  707. :004064FD 33C0                    xor eax, eax
  708. :004064FF EB03                    jmp 00406504
  709. :00406501 8B4020                  mov eax, [eax+20]
  710. :00406504 6A00                    push 00000000
  711. ... the instruction
  712. :004064FB 7504                    jne 00406501
  713. with the instruction 7500 (or 90 90)?
  714. MOST BRILLIANT!
  715. Now we XOR ANYWAY THIS AX without caring for ax+20. The nagscreen
  716. is defeated? Not really... the nagscreen has been passed ON THE
  717. BACKGROUND, where it still remains when you shut the 'main'
  718. window of the program... the nag protection is somewhere there,
  719. looking at us square in the faces... but where?
  720. +gthorne here: since i had already seen the production version
  721. of paint shop pro, i realized that it also had a nag screen - not
  722. per se, but a splash screen (the very same screen without the
  723. buttons to push and the 'number of days elapsed' warning). what
  724. this means is that it is very possible that the screen
  725. (regardless of what version we are running) could be intermingled
  726. with the rest of the code, and not fully existing within a
  727. call. This does not proved it, just allowed the possibility.
  728.  
  729. Poking around, and being playful, i fired up snap32 and grabbed
  730. the nagscreen window and saved it for future reference.
  731.  
  732. The next thing i did was check into the help screen area of Paint
  733. Shop Pro. Often in shareware programs there is a HELP ABOUT, or
  734. a HELP REGISTER section. Sometimes those places give away good
  735. info needed (or just plain useful) in the crack routine.
  736.  
  737. Something that stood out in the help area was the paint shop pro
  738. version statement. It seemed to be identical to the printed
  739. version as seen on the nag screen. That means one of two things:
  740. either the version number string was just typed in twice, or more
  741. likely, just another call to a function: PSP_VERSION() or
  742. somesuch.
  743.  
  744. What that means for the crackist should be pretty clearly a way
  745. to locate the protection routine. Since the word SHAREWARE shows
  746. up in both version calls, it can be scanned for pretty easily
  747. with either that or the word VERSION itself.
  748.  
  749. Then, once i felt i had done enough scouting the territory, I ran
  750. WDASM and grabbed myself a dead listing. Scanning for SHAREWARE,
  751. I found a couple easy references to it... one being a data string
  752. that I promptly blanked out and the other being in the text that
  753. comes up on the nagscreen itself. WELL WELL...
  754.  
  755.   This is the nagscreen result here:
  756.  
  757. * StringData Ref from Data Obj ->"This is a shareware version
  758.                                 of "Paint Shop Pro."
  759.                                   |
  760. :00406B64 6810A34B00              push 004BA310
  761. :00406B69 8D4DEC                  lea ecx, [ebp-14]
  762.  
  763. Okay, running the program again, and firing softice (old friend)
  764. i immediately saw that the version checking routine no longer
  765. tacked on the word SHAREWARE in either the nagscreen or in the
  766. help box.. thus proving the version call to be just that.. a call
  767. (as suspected).
  768.  
  769. Immediately, something else came up that I was not expecting, the
  770. location of most of the program in memory was exactly the same
  771. as seen with softice that it was hardcoded into the disassembly.
  772. What i mean by that is that where softice was reporting
  773. 0137:0043FAD1 for a location in memory, identical data was
  774. reported at location :0043FAD1 on the disassembly.
  775.  
  776. Now, talk about convenient!
  777.  
  778. Simply enough, i breakpointed in softice with a few locations i
  779. had located in the disassembly, and voila... landed smack in the
  780. middle of the nagscreen data.
  781.  
  782. It was do-able with soft-ice alone, but tracing into the maze of
  783. nested calls in PSP really wasn't worth my time.
  784.  
  785. Line-by-line'ing it, it was simple to watch the nagscreen build
  786. itself call by call, and NOP or alter JZ's & JNZ's to JMP's (74's
  787. and 75's become EB's) so that the nagscreen lost more and more
  788. functionality.
  789.  
  790. Then came a little work - not too much, but some things were a
  791. little funny. Notice the BITBLT in the nagscreen creation code.
  792. I had tried to scan for some of the standard SHOWWINDOW calls
  793. with softice and in the disassembly, but not one was to be found
  794. where it needed to be. Apparently PSP was using some other method
  795. of showing the screen... and a simple graphics memory copy (known
  796. to those who follow Micro$oft as a BitBlt) was apparently the
  797. modus operandi.
  798.  
  799. Some of the text was already in place before the BitBlt, so here
  800. is our reason that some of the nagscreen was not being done as
  801. we watched with the debugger... it was being written to a
  802. backbuffer before being copied as a whole window before being
  803. blitted to the screen. This, for those of you new to graphics
  804. programming, is how people make smooth animation that does not
  805. flicker... all of the animating is done in the background and a
  806. whole screen is blitted at one time rather than by bits and
  807. pieces (you can tell which programs do not do this very easily
  808. since they have images that seem to disappear or flicker wrong
  809. in odd places on the screen)
  810.  
  811. There were not many calls in that area, and only the ones that
  812. referenced string data or the bitblt itself could be effectively
  813. nop'ed out.
  814.  
  815. Here is where i basically stopped the work, since i was having
  816. trouble locating what CALLED the nagscreen area.
  817.  
  818. The reason we are getting the ghost window in the back (notice
  819. it's size is EXACTLY the same as the nagscreen, is that windows
  820. is being instructed by some window create command to block off
  821. the rectangular space for the screen even though the graphic
  822. interior does not get written.
  823.  
  824. The crack that puts the nagscreen on the backgrpund is invaluable here since the ghost window does not have a way to be removed without paint shop pro closing (which
  825. cleans up nicely for itself on exit).
  826.  
  827. Now we need to locate the call that creates the window in the
  828. first place and nop it or whatever... there is probably a nicer
  829. way to do all this (if you work at it, you can probably jmp past
  830. all the functions i nop'd - taking care not to leave unmatched
  831. pushes or pops which ruin the flow of the program - at some point
  832. in the nagscreen area
  833.  
  834. The funny part of all this is that our cracked version will be
  835. better than the registered version since the registered version
  836. has a splash screen anyway - and ours does not :)
  837.  
  838. Using all of this knowledge later can actually benefit us in a
  839. different way... we can actually use all of the techniques (since
  840. we already know where the nagscreen is) on the executable of the
  841. full version as well.
  842. Since it has no nag functions, it is a smaller executable and
  843. cracking it will give is a nagless, splashless (eg. screenless)
  844. version of paint shop pro that is smaller (i.e. better and more
  845. functional) than by just cracking the shareware version.
  846.  
  847. I find that funny somehow :)
  848.  
  849. So here is all the rest you need:
  850.  
  851. Let's have a look at the VERSION subroutine that is called both
  852. in the nagscreen and the HELP screen:
  853.  
  854. * StringData Ref from Data Obj ->"4" ;FIRST DIGIT OF VERSION 4.01
  855.                                   |
  856. :004350E4 6874AE4B00              push 004BAE74
  857. :004350E9 8B3D90004C00            mov edi, [004C0090]
  858. :004350EF C645FC07                mov [ebp-04], 07
  859. :004350F3 C706F0A54A00            mov dword ptr [esi], 004AA5F0
  860. :004350F9 FFD7                    call edi
  861. :004350FB 83C404                  add esp, 00000004
  862. :004350FE 8BD8                    mov ebx, eax
  863. :00435100 C1E310                  shl ebx, 10
  864.  
  865. * StringData Ref from Data Obj ->"0"    ;SECOND DIGIT OF 4.01
  866.                                   |
  867. :00435103 6860A64B00              push 004BA660
  868. :00435108 FFD7                    call edi
  869. :0043510A 83C404                  add esp, 00000004
  870. :0043510D 0BD8                    or ebx, eax
  871. :0043510F C1E308                  shl ebx, 08
  872.  
  873. * StringData Ref from Data Obj ->"1"   ;THIRD DIGIT OF 4.01
  874.                                   |
  875. :00435112 685CA64B00              push 004BA65C
  876. :00435117 FFD7                    call edi
  877. :00435119 C1E010                  shl eax, 10
  878. :0043511C 83C404                  add esp, 00000004
  879. :0043511F 0BD8                    or ebx, eax
  880.  
  881. * Possible StringData Ref from Data Obj ->"2"
  882.                                   |
  883. :00435121 68C4A14B00              push 004BA1C4
  884. :00435126 FFD7                    call edi
  885. :00435128 83C404                  add esp, 00000004
  886. :0043512B 0BD8                    or ebx, eax
  887. :0043512D 899ED4000000            mov [esi-000000D4], ebx
  888.  
  889. * Possible StringData Ref from Data Obj ->"0"
  890.                                   |
  891. :00435133 6860A64B00              push 004BA660
  892. :00435138 FFD7                    call edi
  893. :0043513A 83C404                  add esp, 00000004
  894. :0043513D 50                      push eax
  895.  
  896. * Possible StringData Ref from Data Obj ->"1"
  897.                                   |
  898. :0043513E 685CA64B00              push 004BA65C
  899. :00435143 FFD7                    call edi
  900. :00435145 83C404                  add esp, 00000004
  901. :00435148 50                      push eax
  902.  
  903. * Possible StringData Ref from Data Obj ->"4"
  904.                                   |
  905. :00435149 6874AE4B00              push 004BAE74
  906. :0043514E FFD7                    call edi
  907. :00435150 83C404                  add esp, 00000004
  908. :00435153 50                      push eax
  909.  
  910. * Ref from Data Obj ->"%i.%i%i"  ;PRINT 3 INTEGERS: N.NN (4.01)
  911.                                   |
  912. :00435154 686CAE4B00              push 004BAE6C
  913. :00435159 8D86CC000000            lea eax, [esi-000000CC]
  914. :0043515F 50                      push eax
  915.  
  916. * Reference To: n/a, Ord:09A7h in MFC40.DLL
  917.                                   |
  918. :00435160 E815FF0600              call 004A507A
  919. :00435165 83C414                  add esp, 00000014
  920. :00435168 8D8ECC000000            lea ecx, [esi-000000CC]
  921.  
  922. * StringData Ref from Data Obj ->" Shareware"  ;PRINT SHAREWARE
  923.                                   |
  924. :0043516E 6860AE4B00              push 004BAE60
  925.  
  926. The first BitBlt routine of the program puts the screen on!
  927.  
  928. it is at:
  929.  
  930. * Reference To: BitBlt, Ord:000Ah in GDI32.dll
  931.                                   |
  932. :00406917 FF15B4F24B00            call dword ptr [004BF2B4]
  933. :0040691D B800000000              mov eax, 00000000
  934. :00406922 85FF                    test edi, edi
  935. :00406924 7403                    je 00406929
  936. :00406926 8B4704                  mov eax, [edi+04]
  937. :00406929 50                      push eax
  938. :0040692A 8B45B4                  mov eax, [ebp-4C]
  939. :0040692D 50                      push eax
  940.  
  941. and here some other annoying pieces of code: The red bar as soon
  942. as you use the program more than 30 days...
  943.  
  944. * Reference To: n/a, Ord:0970h in MFC40.DLL
  945.                                   |
  946. :00406BE3 E836E60900    call 004A521E ;DRAW RED BAR
  947. :00406BE8 6801080000    push 00000801
  948. :00406BED 8D45A0        lea eax, [ebp-60]
  949. :00406BF0 50            push eax
  950. :00406BF1 8B4DEC        mov ecx, [ebp-14]
  951. :00406BF4 8B853CFFFFFF  mov eax, [ebp-000000C4]
  952. :00406BFA 8B51F8        mov edx, [ecx-08]
  953. :00406BFD 52            push edx
  954. :00406BFE 51            push ecx
  955. :00406BFF 8D8D3CFFFFFF  lea ecx, [ebp-000000C4]
  956. :00406C05 FF5070        call [eax+70] ;BOTTOM WINDOW TXT+RED BAR
  957. :00406C08 53            push ebx
  958. :00406C09 8D8D3CFFFFFF  lea ecx, [ebp-000000C4]
  959.  
  960. Once found all the above, the rest is pretty obvious... here all
  961. the necessary crackcodes: bytes to find and change. This is a
  962. weird, non-elegant crack, but kinda funny, so i had to write it
  963. down until i discover a better one (greythorne speaking) note:
  964. i gave good search strings so lamers don't get confused with
  965. similar patterns in the software:
  966.  
  967. 8B450885C07504 to 8B450885C07500 - screen backgrounding
  968. 3CFFFFFFFF5070 to 3CFFFFFF750090 - do not draw lower text in box
  969. 3CFFFFFFFF5064 to 3CFFFFFFEB0090 - do not report version number
  970. 83FF1E7E1E to 83FF1EEB1E         - do not draw red bar
  971. 000083FFC07403 to 000083FFC0EB03 - turn nagscreen invisible
  972. 53686172657761726500 to 20202020202020202000 - disable shareware
  973. notice writing phisycally some spaces over it
  974.  
  975. final note: since psp closes the nagscreen when the program
  976. exits, all is now cleaned up.
  977.  
  978.  FF15B4F24B00 to 750090750090 (bitblt) seems to not do anything
  979. the above cracks dont do.
  980.  
  981. FraVia+ here: Time to explain BitBlt... isn 't it? BitBlt copies
  982. a bitmap from the device context sopecified by hdcSource to the
  983. device context specified by hdcTarget performing a block copy.
  984. On success the function returns not zero.
  985. It is called with the handle hdcTarget, int nTargetX and nTArgetY
  986. (upper left coordinates of the point at which the bitmap will be
  987. copied... a 'pixel point' locator may be very useful in our
  988. trade) int nWidth and nHeight of the region, the handle hdcSource
  989. and then, finally the upper left coordinates IN the bitmap, the
  990. two int nSourceX and nSourcey. Is it all? NO! The final
  991. parameter, DWORD dwRaster determines HOW the bit-by-bit contents
  992. of the bitmap will actually be copied (black, inverted, ANDed,
  993. ORed, XOred...etc.).
  994.  
  995. Lotta things to learn if you want to crack a lot...
  996. THE STUDENTS OF UNIT 4 (+HCU, January 1997)
  997. *******************************************
  998.  
  999. As a matter of fact both cracks here, mine for PSPS32 and my
  1000. student's VERY smart one for PSP41 are 'weak', though: they will
  1001. not eliminate the nagscreen (you should search for the remaining
  1002. occurrences of our locations and work from them inwards, if you
  1003. really want to crack completely this scheme, but in this case it
  1004. would be better to work more with Winice95, in my opinion. But
  1005. I hope I have made the point about "dead listing" cracking: It
  1006. works! Quick and placid! In the PSP32 case the protection will
  1007. still show you the nagscreen, which will "automatically"
  1008. disappear, though, leaving you with no annoyance (in nuce: you
  1009. cracked the return button), in the other case you have physically
  1010. eliminated all possible annoyances. The nagscreen is still there,
  1011. but it does not 'harm' you any more.
  1012. Anyway I wanted only to show you the POWER and the CHILD'S PLAY
  1013. working of this "dead listing" approach (that you may combine
  1014. with some quick winice probes if you really think you need it
  1015. anytime).
  1016.      You'll agree with me, though, that this quick "weak" crack,
  1017. made with the "dead listing" method is far less tiresome than a
  1018. 'live' crack with our beloved SoftIce/WinIce.
  1019.      Now, in life, I believe, you should always search to obtain
  1020. the maximum giving the minimum. There is no point in being
  1021. altruistic or excessively honest in a society where the tiny
  1022. minority that profits most keeps getting richer and richer and
  1023. the overwhelming majority that lives with meager earnings keeps
  1024. getting poorer and poorer (and -moronized by TV-watching and
  1025. other Pavlovian propagandistic sources of misinformation- keeps
  1026. voting the same rich bastards that keep it enslaved under the
  1027. whips of publicity, as if the slaves of ancient Egypt would
  1028. happily vote for their Pharaohs). I abhor and despise the society
  1029. I am compelled to live in... but this does not mean that I
  1030. renounce to anything. I am (pretty) rich, (yet do not exploit
  1031. anybody), eat very well, have a big nice house with all the
  1032. useless objects and cars and garages and terraces and futile
  1033. gadgets you are supposed to enjoy in this moronic society (I
  1034. enjoy foremost my spacious library) and I drink my regular bottle
  1035. of (Moskowskaja) Wodka every week. My liver (and my nice family)
  1036. do not seem to complain :=)
  1037.  
  1038. Well, that's it for this lesson, reader. Not all lessons of my
  1039. tutorial are or will be on the Web.
  1040.      You'll obtain the missing lessons IF AND ONLY IF you mail
  1041. me back (via anon.penet.fi) with some tricks of the trade I may
  1042. not know that YOU discovered. Mostly I'll actually know them
  1043. already, but if they are really new you'll be given full credit,
  1044. and even if they are not, should I judge that you "rediscovered"
  1045. them with your work, or that you actually did good work on them,
  1046. I'll send you the remaining lessons nevertheless. Your
  1047. suggestions and critics on the whole crap I wrote are also
  1048. welcomed. Do not annoy me with requests for warez, everything is
  1049. on the Web, learn how to search, for goddess sake.
  1050.  
  1051.      "If you give a man a crack he'll be hungry again
  1052.      tomorrow, but if you teach him how to crack, he'll
  1053.      never be hungry again"
  1054.  
  1055.                                 E-mail +ORC
  1056.  
  1057.                         +ORC na526164@anon.penet.fi
  1058.  
  1059. 
  1060.